<template>
  <div>
    <input type="text" name="" v-model="msg" />
    <button @click="send">向父组件传递信息</button>
    <slot name="solta" :soltmsg="soltmsg"></slot>
  </div>
</template>

<script>
export default {
  data() {
    return {
      msg: "",
      soltmsg:"solt4324",
    };
  },
  methods:{
    send(){
        this.$emit("send",this.msg)
    }
  }
};
</script>

<style lang="scss" scoped>
</style>